3.6.84 \(\int \cot ^6(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x)) \, dx\) [584]

3.6.84.1 Optimal result
3.6.84.2 Mathematica [A] (verified)
3.6.84.3 Rubi [A] (verified)
3.6.84.4 Maple [A] (verified)
3.6.84.5 Fricas [B] (verification not implemented)
3.6.84.6 Sympy [F(-1)]
3.6.84.7 Maxima [A] (verification not implemented)
3.6.84.8 Giac [B] (verification not implemented)
3.6.84.9 Mupad [B] (verification not implemented)

3.6.84.1 Optimal result

Integrand size = 27, antiderivative size = 122 \[ \int \cot ^6(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x)) \, dx=\frac {5 a \text {arctanh}(\cos (c+d x))}{128 d}-\frac {a \cot ^7(c+d x)}{7 d}+\frac {5 a \cot (c+d x) \csc (c+d x)}{128 d}-\frac {5 a \cot (c+d x) \csc ^3(c+d x)}{64 d}+\frac {5 a \cot ^3(c+d x) \csc ^3(c+d x)}{48 d}-\frac {a \cot ^5(c+d x) \csc ^3(c+d x)}{8 d} \]

output
5/128*a*arctanh(cos(d*x+c))/d-1/7*a*cot(d*x+c)^7/d+5/128*a*cot(d*x+c)*csc( 
d*x+c)/d-5/64*a*cot(d*x+c)*csc(d*x+c)^3/d+5/48*a*cot(d*x+c)^3*csc(d*x+c)^3 
/d-1/8*a*cot(d*x+c)^5*csc(d*x+c)^3/d
 
3.6.84.2 Mathematica [A] (verified)

Time = 0.20 (sec) , antiderivative size = 215, normalized size of antiderivative = 1.76 \[ \int \cot ^6(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x)) \, dx=-\frac {a \cot ^7(c+d x)}{7 d}+\frac {5 a \csc ^2\left (\frac {1}{2} (c+d x)\right )}{512 d}-\frac {15 a \csc ^4\left (\frac {1}{2} (c+d x)\right )}{1024 d}+\frac {7 a \csc ^6\left (\frac {1}{2} (c+d x)\right )}{1536 d}-\frac {a \csc ^8\left (\frac {1}{2} (c+d x)\right )}{2048 d}+\frac {5 a \log \left (\cos \left (\frac {1}{2} (c+d x)\right )\right )}{128 d}-\frac {5 a \log \left (\sin \left (\frac {1}{2} (c+d x)\right )\right )}{128 d}-\frac {5 a \sec ^2\left (\frac {1}{2} (c+d x)\right )}{512 d}+\frac {15 a \sec ^4\left (\frac {1}{2} (c+d x)\right )}{1024 d}-\frac {7 a \sec ^6\left (\frac {1}{2} (c+d x)\right )}{1536 d}+\frac {a \sec ^8\left (\frac {1}{2} (c+d x)\right )}{2048 d} \]

input
Integrate[Cot[c + d*x]^6*Csc[c + d*x]^3*(a + a*Sin[c + d*x]),x]
 
output
-1/7*(a*Cot[c + d*x]^7)/d + (5*a*Csc[(c + d*x)/2]^2)/(512*d) - (15*a*Csc[( 
c + d*x)/2]^4)/(1024*d) + (7*a*Csc[(c + d*x)/2]^6)/(1536*d) - (a*Csc[(c + 
d*x)/2]^8)/(2048*d) + (5*a*Log[Cos[(c + d*x)/2]])/(128*d) - (5*a*Log[Sin[( 
c + d*x)/2]])/(128*d) - (5*a*Sec[(c + d*x)/2]^2)/(512*d) + (15*a*Sec[(c + 
d*x)/2]^4)/(1024*d) - (7*a*Sec[(c + d*x)/2]^6)/(1536*d) + (a*Sec[(c + d*x) 
/2]^8)/(2048*d)
 
3.6.84.3 Rubi [A] (verified)

Time = 0.75 (sec) , antiderivative size = 135, normalized size of antiderivative = 1.11, number of steps used = 15, number of rules used = 14, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.519, Rules used = {3042, 3317, 3042, 3087, 15, 3091, 3042, 3091, 3042, 3091, 3042, 4255, 3042, 4257}

Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.

\(\displaystyle \int \cot ^6(c+d x) \csc ^3(c+d x) (a \sin (c+d x)+a) \, dx\)

\(\Big \downarrow \) 3042

\(\displaystyle \int \frac {\cos (c+d x)^6 (a \sin (c+d x)+a)}{\sin (c+d x)^9}dx\)

\(\Big \downarrow \) 3317

\(\displaystyle a \int \cot ^6(c+d x) \csc ^3(c+d x)dx+a \int \cot ^6(c+d x) \csc ^2(c+d x)dx\)

\(\Big \downarrow \) 3042

\(\displaystyle a \int \sec \left (c+d x-\frac {\pi }{2}\right )^2 \tan \left (c+d x-\frac {\pi }{2}\right )^6dx+a \int \sec \left (c+d x-\frac {\pi }{2}\right )^3 \tan \left (c+d x-\frac {\pi }{2}\right )^6dx\)

\(\Big \downarrow \) 3087

\(\displaystyle \frac {a \int \cot ^6(c+d x)d(-\cot (c+d x))}{d}+a \int \sec \left (c+d x-\frac {\pi }{2}\right )^3 \tan \left (c+d x-\frac {\pi }{2}\right )^6dx\)

\(\Big \downarrow \) 15

\(\displaystyle a \int \sec \left (c+d x-\frac {\pi }{2}\right )^3 \tan \left (c+d x-\frac {\pi }{2}\right )^6dx-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 3091

\(\displaystyle a \left (-\frac {5}{8} \int \cot ^4(c+d x) \csc ^3(c+d x)dx-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 3042

\(\displaystyle a \left (-\frac {5}{8} \int \sec \left (c+d x-\frac {\pi }{2}\right )^3 \tan \left (c+d x-\frac {\pi }{2}\right )^4dx-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 3091

\(\displaystyle a \left (-\frac {5}{8} \left (-\frac {1}{2} \int \cot ^2(c+d x) \csc ^3(c+d x)dx-\frac {\cot ^3(c+d x) \csc ^3(c+d x)}{6 d}\right )-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 3042

\(\displaystyle a \left (-\frac {5}{8} \left (-\frac {1}{2} \int \sec \left (c+d x-\frac {\pi }{2}\right )^3 \tan \left (c+d x-\frac {\pi }{2}\right )^2dx-\frac {\cot ^3(c+d x) \csc ^3(c+d x)}{6 d}\right )-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 3091

\(\displaystyle a \left (-\frac {5}{8} \left (\frac {1}{2} \left (\frac {1}{4} \int \csc ^3(c+d x)dx+\frac {\cot (c+d x) \csc ^3(c+d x)}{4 d}\right )-\frac {\cot ^3(c+d x) \csc ^3(c+d x)}{6 d}\right )-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 3042

\(\displaystyle a \left (-\frac {5}{8} \left (\frac {1}{2} \left (\frac {1}{4} \int \csc (c+d x)^3dx+\frac {\cot (c+d x) \csc ^3(c+d x)}{4 d}\right )-\frac {\cot ^3(c+d x) \csc ^3(c+d x)}{6 d}\right )-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 4255

\(\displaystyle a \left (-\frac {5}{8} \left (\frac {1}{2} \left (\frac {1}{4} \left (\frac {1}{2} \int \csc (c+d x)dx-\frac {\cot (c+d x) \csc (c+d x)}{2 d}\right )+\frac {\cot (c+d x) \csc ^3(c+d x)}{4 d}\right )-\frac {\cot ^3(c+d x) \csc ^3(c+d x)}{6 d}\right )-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 3042

\(\displaystyle a \left (-\frac {5}{8} \left (\frac {1}{2} \left (\frac {1}{4} \left (\frac {1}{2} \int \csc (c+d x)dx-\frac {\cot (c+d x) \csc (c+d x)}{2 d}\right )+\frac {\cot (c+d x) \csc ^3(c+d x)}{4 d}\right )-\frac {\cot ^3(c+d x) \csc ^3(c+d x)}{6 d}\right )-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

\(\Big \downarrow \) 4257

\(\displaystyle a \left (-\frac {5}{8} \left (\frac {1}{2} \left (\frac {1}{4} \left (-\frac {\text {arctanh}(\cos (c+d x))}{2 d}-\frac {\cot (c+d x) \csc (c+d x)}{2 d}\right )+\frac {\cot (c+d x) \csc ^3(c+d x)}{4 d}\right )-\frac {\cot ^3(c+d x) \csc ^3(c+d x)}{6 d}\right )-\frac {\cot ^5(c+d x) \csc ^3(c+d x)}{8 d}\right )-\frac {a \cot ^7(c+d x)}{7 d}\)

input
Int[Cot[c + d*x]^6*Csc[c + d*x]^3*(a + a*Sin[c + d*x]),x]
 
output
-1/7*(a*Cot[c + d*x]^7)/d + a*(-1/8*(Cot[c + d*x]^5*Csc[c + d*x]^3)/d - (5 
*(-1/6*(Cot[c + d*x]^3*Csc[c + d*x]^3)/d + ((Cot[c + d*x]*Csc[c + d*x]^3)/ 
(4*d) + (-1/2*ArcTanh[Cos[c + d*x]]/d - (Cot[c + d*x]*Csc[c + d*x])/(2*d)) 
/4)/2))/8)
 

3.6.84.3.1 Defintions of rubi rules used

rule 15
Int[(a_.)*(x_)^(m_.), x_Symbol] :> Simp[a*(x^(m + 1)/(m + 1)), x] /; FreeQ[ 
{a, m}, x] && NeQ[m, -1]
 

rule 3042
Int[u_, x_Symbol] :> Int[DeactivateTrig[u, x], x] /; FunctionOfTrigOfLinear 
Q[u, x]
 

rule 3087
Int[sec[(e_.) + (f_.)*(x_)]^(m_)*((b_.)*tan[(e_.) + (f_.)*(x_)])^(n_.), x_S 
ymbol] :> Simp[1/f   Subst[Int[(b*x)^n*(1 + x^2)^(m/2 - 1), x], x, Tan[e + 
f*x]], x] /; FreeQ[{b, e, f, n}, x] && IntegerQ[m/2] &&  !(IntegerQ[(n - 1) 
/2] && LtQ[0, n, m - 1])
 

rule 3091
Int[((a_.)*sec[(e_.) + (f_.)*(x_)])^(m_.)*((b_.)*tan[(e_.) + (f_.)*(x_)])^( 
n_), x_Symbol] :> Simp[b*(a*Sec[e + f*x])^m*((b*Tan[e + f*x])^(n - 1)/(f*(m 
 + n - 1))), x] - Simp[b^2*((n - 1)/(m + n - 1))   Int[(a*Sec[e + f*x])^m*( 
b*Tan[e + f*x])^(n - 2), x], x] /; FreeQ[{a, b, e, f, m}, x] && GtQ[n, 1] & 
& NeQ[m + n - 1, 0] && IntegersQ[2*m, 2*n]
 

rule 3317
Int[(cos[(e_.) + (f_.)*(x_)]*(g_.))^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n 
_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]), x_Symbol] :> Simp[a   Int[(g*Co 
s[e + f*x])^p*(d*Sin[e + f*x])^n, x], x] + Simp[b/d   Int[(g*Cos[e + f*x])^ 
p*(d*Sin[e + f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, g, n, p}, x]
 

rule 4255
Int[(csc[(c_.) + (d_.)*(x_)]*(b_.))^(n_), x_Symbol] :> Simp[(-b)*Cos[c + d* 
x]*((b*Csc[c + d*x])^(n - 1)/(d*(n - 1))), x] + Simp[b^2*((n - 2)/(n - 1)) 
  Int[(b*Csc[c + d*x])^(n - 2), x], x] /; FreeQ[{b, c, d}, x] && GtQ[n, 1] 
&& IntegerQ[2*n]
 

rule 4257
Int[csc[(c_.) + (d_.)*(x_)], x_Symbol] :> Simp[-ArcTanh[Cos[c + d*x]]/d, x] 
 /; FreeQ[{c, d}, x]
 
3.6.84.4 Maple [A] (verified)

Time = 0.44 (sec) , antiderivative size = 144, normalized size of antiderivative = 1.18

method result size
parallelrisch \(-\frac {1765 \left (\frac {49152 \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{353}+\left (\sec \left (\frac {d x}{2}+\frac {c}{2}\right ) \left (\cos \left (d x +c \right )+\frac {179 \cos \left (3 d x +3 c \right )}{353}+\frac {397 \cos \left (5 d x +5 c \right )}{1765}+\frac {3 \cos \left (7 d x +7 c \right )}{353}\right ) \csc \left (\frac {d x}{2}+\frac {c}{2}\right )+\frac {768 \cos \left (d x +c \right )}{353}+\frac {2304 \cos \left (3 d x +3 c \right )}{1765}+\frac {768 \cos \left (5 d x +5 c \right )}{1765}+\frac {768 \cos \left (7 d x +7 c \right )}{12355}\right ) \left (\sec ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right ) \left (\csc ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )\right ) a}{6291456 d}\) \(144\)
derivativedivides \(\frac {-\frac {a \left (\cos ^{7}\left (d x +c \right )\right )}{7 \sin \left (d x +c \right )^{7}}+a \left (-\frac {\cos ^{7}\left (d x +c \right )}{8 \sin \left (d x +c \right )^{8}}-\frac {\cos ^{7}\left (d x +c \right )}{48 \sin \left (d x +c \right )^{6}}+\frac {\cos ^{7}\left (d x +c \right )}{192 \sin \left (d x +c \right )^{4}}-\frac {\cos ^{7}\left (d x +c \right )}{128 \sin \left (d x +c \right )^{2}}-\frac {\left (\cos ^{5}\left (d x +c \right )\right )}{128}-\frac {5 \left (\cos ^{3}\left (d x +c \right )\right )}{384}-\frac {5 \cos \left (d x +c \right )}{128}-\frac {5 \ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{128}\right )}{d}\) \(146\)
default \(\frac {-\frac {a \left (\cos ^{7}\left (d x +c \right )\right )}{7 \sin \left (d x +c \right )^{7}}+a \left (-\frac {\cos ^{7}\left (d x +c \right )}{8 \sin \left (d x +c \right )^{8}}-\frac {\cos ^{7}\left (d x +c \right )}{48 \sin \left (d x +c \right )^{6}}+\frac {\cos ^{7}\left (d x +c \right )}{192 \sin \left (d x +c \right )^{4}}-\frac {\cos ^{7}\left (d x +c \right )}{128 \sin \left (d x +c \right )^{2}}-\frac {\left (\cos ^{5}\left (d x +c \right )\right )}{128}-\frac {5 \left (\cos ^{3}\left (d x +c \right )\right )}{384}-\frac {5 \cos \left (d x +c \right )}{128}-\frac {5 \ln \left (\csc \left (d x +c \right )-\cot \left (d x +c \right )\right )}{128}\right )}{d}\) \(146\)
risch \(-\frac {a \left (105 \,{\mathrm e}^{15 i \left (d x +c \right )}+2779 \,{\mathrm e}^{13 i \left (d x +c \right )}-13440 i {\mathrm e}^{10 i \left (d x +c \right )}+6265 \,{\mathrm e}^{11 i \left (d x +c \right )}-2688 i {\mathrm e}^{14 i \left (d x +c \right )}+12355 \,{\mathrm e}^{9 i \left (d x +c \right )}+8064 i {\mathrm e}^{4 i \left (d x +c \right )}+12355 \,{\mathrm e}^{7 i \left (d x +c \right )}+13440 i {\mathrm e}^{8 i \left (d x +c \right )}+6265 \,{\mathrm e}^{5 i \left (d x +c \right )}-384 i {\mathrm e}^{2 i \left (d x +c \right )}+2779 \,{\mathrm e}^{3 i \left (d x +c \right )}-8064 i {\mathrm e}^{6 i \left (d x +c \right )}+105 \,{\mathrm e}^{i \left (d x +c \right )}+2688 i {\mathrm e}^{12 i \left (d x +c \right )}+384 i\right )}{1344 d \left ({\mathrm e}^{2 i \left (d x +c \right )}-1\right )^{8}}-\frac {5 a \ln \left ({\mathrm e}^{i \left (d x +c \right )}-1\right )}{128 d}+\frac {5 a \ln \left ({\mathrm e}^{i \left (d x +c \right )}+1\right )}{128 d}\) \(232\)

input
int(cos(d*x+c)^6*csc(d*x+c)^9*(a+a*sin(d*x+c)),x,method=_RETURNVERBOSE)
 
output
-1765/6291456*(49152/353*ln(tan(1/2*d*x+1/2*c))+(sec(1/2*d*x+1/2*c)*(cos(d 
*x+c)+179/353*cos(3*d*x+3*c)+397/1765*cos(5*d*x+5*c)+3/353*cos(7*d*x+7*c)) 
*csc(1/2*d*x+1/2*c)+768/353*cos(d*x+c)+2304/1765*cos(3*d*x+3*c)+768/1765*c 
os(5*d*x+5*c)+768/12355*cos(7*d*x+7*c))*sec(1/2*d*x+1/2*c)^7*csc(1/2*d*x+1 
/2*c)^7)*a/d
 
3.6.84.5 Fricas [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 225 vs. \(2 (110) = 220\).

Time = 0.27 (sec) , antiderivative size = 225, normalized size of antiderivative = 1.84 \[ \int \cot ^6(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x)) \, dx=-\frac {768 \, a \cos \left (d x + c\right )^{7} \sin \left (d x + c\right ) + 210 \, a \cos \left (d x + c\right )^{7} + 1022 \, a \cos \left (d x + c\right )^{5} - 770 \, a \cos \left (d x + c\right )^{3} + 210 \, a \cos \left (d x + c\right ) - 105 \, {\left (a \cos \left (d x + c\right )^{8} - 4 \, a \cos \left (d x + c\right )^{6} + 6 \, a \cos \left (d x + c\right )^{4} - 4 \, a \cos \left (d x + c\right )^{2} + a\right )} \log \left (\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) + 105 \, {\left (a \cos \left (d x + c\right )^{8} - 4 \, a \cos \left (d x + c\right )^{6} + 6 \, a \cos \left (d x + c\right )^{4} - 4 \, a \cos \left (d x + c\right )^{2} + a\right )} \log \left (-\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right )}{5376 \, {\left (d \cos \left (d x + c\right )^{8} - 4 \, d \cos \left (d x + c\right )^{6} + 6 \, d \cos \left (d x + c\right )^{4} - 4 \, d \cos \left (d x + c\right )^{2} + d\right )}} \]

input
integrate(cos(d*x+c)^6*csc(d*x+c)^9*(a+a*sin(d*x+c)),x, algorithm="fricas" 
)
 
output
-1/5376*(768*a*cos(d*x + c)^7*sin(d*x + c) + 210*a*cos(d*x + c)^7 + 1022*a 
*cos(d*x + c)^5 - 770*a*cos(d*x + c)^3 + 210*a*cos(d*x + c) - 105*(a*cos(d 
*x + c)^8 - 4*a*cos(d*x + c)^6 + 6*a*cos(d*x + c)^4 - 4*a*cos(d*x + c)^2 + 
 a)*log(1/2*cos(d*x + c) + 1/2) + 105*(a*cos(d*x + c)^8 - 4*a*cos(d*x + c) 
^6 + 6*a*cos(d*x + c)^4 - 4*a*cos(d*x + c)^2 + a)*log(-1/2*cos(d*x + c) + 
1/2))/(d*cos(d*x + c)^8 - 4*d*cos(d*x + c)^6 + 6*d*cos(d*x + c)^4 - 4*d*co 
s(d*x + c)^2 + d)
 
3.6.84.6 Sympy [F(-1)]

Timed out. \[ \int \cot ^6(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x)) \, dx=\text {Timed out} \]

input
integrate(cos(d*x+c)**6*csc(d*x+c)**9*(a+a*sin(d*x+c)),x)
 
output
Timed out
 
3.6.84.7 Maxima [A] (verification not implemented)

Time = 0.23 (sec) , antiderivative size = 126, normalized size of antiderivative = 1.03 \[ \int \cot ^6(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x)) \, dx=-\frac {7 \, a {\left (\frac {2 \, {\left (15 \, \cos \left (d x + c\right )^{7} + 73 \, \cos \left (d x + c\right )^{5} - 55 \, \cos \left (d x + c\right )^{3} + 15 \, \cos \left (d x + c\right )\right )}}{\cos \left (d x + c\right )^{8} - 4 \, \cos \left (d x + c\right )^{6} + 6 \, \cos \left (d x + c\right )^{4} - 4 \, \cos \left (d x + c\right )^{2} + 1} - 15 \, \log \left (\cos \left (d x + c\right ) + 1\right ) + 15 \, \log \left (\cos \left (d x + c\right ) - 1\right )\right )} + \frac {768 \, a}{\tan \left (d x + c\right )^{7}}}{5376 \, d} \]

input
integrate(cos(d*x+c)^6*csc(d*x+c)^9*(a+a*sin(d*x+c)),x, algorithm="maxima" 
)
 
output
-1/5376*(7*a*(2*(15*cos(d*x + c)^7 + 73*cos(d*x + c)^5 - 55*cos(d*x + c)^3 
 + 15*cos(d*x + c))/(cos(d*x + c)^8 - 4*cos(d*x + c)^6 + 6*cos(d*x + c)^4 
- 4*cos(d*x + c)^2 + 1) - 15*log(cos(d*x + c) + 1) + 15*log(cos(d*x + c) - 
 1)) + 768*a/tan(d*x + c)^7)/d
 
3.6.84.8 Giac [B] (verification not implemented)

Leaf count of result is larger than twice the leaf count of optimal. 256 vs. \(2 (110) = 220\).

Time = 0.38 (sec) , antiderivative size = 256, normalized size of antiderivative = 2.10 \[ \int \cot ^6(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x)) \, dx=\frac {21 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{8} + 48 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} - 112 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{6} - 336 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} + 168 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} + 1008 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 336 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 1680 \, a \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) \right |}\right ) - 1680 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) + \frac {4566 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{8} + 1680 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{7} - 336 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{6} - 1008 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{5} - 168 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{4} + 336 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + 112 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} - 48 \, a \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 21 \, a}{\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{8}}}{43008 \, d} \]

input
integrate(cos(d*x+c)^6*csc(d*x+c)^9*(a+a*sin(d*x+c)),x, algorithm="giac")
 
output
1/43008*(21*a*tan(1/2*d*x + 1/2*c)^8 + 48*a*tan(1/2*d*x + 1/2*c)^7 - 112*a 
*tan(1/2*d*x + 1/2*c)^6 - 336*a*tan(1/2*d*x + 1/2*c)^5 + 168*a*tan(1/2*d*x 
 + 1/2*c)^4 + 1008*a*tan(1/2*d*x + 1/2*c)^3 + 336*a*tan(1/2*d*x + 1/2*c)^2 
 - 1680*a*log(abs(tan(1/2*d*x + 1/2*c))) - 1680*a*tan(1/2*d*x + 1/2*c) + ( 
4566*a*tan(1/2*d*x + 1/2*c)^8 + 1680*a*tan(1/2*d*x + 1/2*c)^7 - 336*a*tan( 
1/2*d*x + 1/2*c)^6 - 1008*a*tan(1/2*d*x + 1/2*c)^5 - 168*a*tan(1/2*d*x + 1 
/2*c)^4 + 336*a*tan(1/2*d*x + 1/2*c)^3 + 112*a*tan(1/2*d*x + 1/2*c)^2 - 48 
*a*tan(1/2*d*x + 1/2*c) - 21*a)/tan(1/2*d*x + 1/2*c)^8)/d
 
3.6.84.9 Mupad [B] (verification not implemented)

Time = 10.64 (sec) , antiderivative size = 285, normalized size of antiderivative = 2.34 \[ \int \cot ^6(c+d x) \csc ^3(c+d x) (a+a \sin (c+d x)) \, dx=\frac {5\,a\,\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{128\,d}-\frac {5\,a\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{128\,d}-\frac {a\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2}{128\,d}-\frac {3\,a\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{128\,d}-\frac {a\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4}{256\,d}+\frac {a\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5}{128\,d}+\frac {a\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6}{384\,d}-\frac {a\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7}{896\,d}-\frac {a\,{\mathrm {cot}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8}{2048\,d}+\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2}{128\,d}+\frac {3\,a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3}{128\,d}+\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^4}{256\,d}-\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^5}{128\,d}-\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^6}{384\,d}+\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^7}{896\,d}+\frac {a\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^8}{2048\,d}-\frac {5\,a\,\ln \left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{128\,d} \]

input
int((cos(c + d*x)^6*(a + a*sin(c + d*x)))/sin(c + d*x)^9,x)
 
output
(5*a*cot(c/2 + (d*x)/2))/(128*d) - (5*a*tan(c/2 + (d*x)/2))/(128*d) - (a*c 
ot(c/2 + (d*x)/2)^2)/(128*d) - (3*a*cot(c/2 + (d*x)/2)^3)/(128*d) - (a*cot 
(c/2 + (d*x)/2)^4)/(256*d) + (a*cot(c/2 + (d*x)/2)^5)/(128*d) + (a*cot(c/2 
 + (d*x)/2)^6)/(384*d) - (a*cot(c/2 + (d*x)/2)^7)/(896*d) - (a*cot(c/2 + ( 
d*x)/2)^8)/(2048*d) + (a*tan(c/2 + (d*x)/2)^2)/(128*d) + (3*a*tan(c/2 + (d 
*x)/2)^3)/(128*d) + (a*tan(c/2 + (d*x)/2)^4)/(256*d) - (a*tan(c/2 + (d*x)/ 
2)^5)/(128*d) - (a*tan(c/2 + (d*x)/2)^6)/(384*d) + (a*tan(c/2 + (d*x)/2)^7 
)/(896*d) + (a*tan(c/2 + (d*x)/2)^8)/(2048*d) - (5*a*log(tan(c/2 + (d*x)/2 
)))/(128*d)